#include <iostream>

using namespace std;

class Test
{
public:
    Test()
    {
        cout<< "Test"<<endl;
    }
    ~Test()
    {
        cout<< "~Test"<<endl;
    }

    void func()
    {
        cout << "hello world" <<endl;
    }
    int num ;
};



int main ()
{ 
    //&Test::num
    int Test::*p = &Test::num;//获取某个成员的地址
    void (Test::*p_func)()= &Test::func;
    printf("%p\n", p);
    return 0;
}